package demo.issuetracker.dao;

import java.util.ArrayList;
import java.util.List;
import java.util.Map;
import java.util.UUID;

import demo.issuetracker.entity.Issue;

public interface IssueDao {
    /**
     * The "Create" semantics of "CRUD"
     */
    public void create(Issue issue);

    /**
     * Create a new instance of this object
     */
    public Issue newInstance();

    /**
     * The "Update" semantics of "CRUD"
     */
    public void update(Issue issue);
    

    /**
     * Find by Primary key
     * 
     * The "read" operation of CRUD
     */
    public Issue findByPrimaryKey(String key);


    /**
     * The "Create" or "Update" semantics of "CRUD"
     */
    public void createOrUpdate(Issue issue);

    /**
     * The "delete" semantics of "CRUD"
     */
    public void delete(Issue issue);


    /**
     * All Issues. Display all Issues in the system.
     * 
     * The "read" operation of CRUD
     */
    public List<Issue> findIssueList(Map<String, Object> params);

    /**
     * My Team's Issues. All issues belonging to user's team
     * 
     * $fact.text
     * 
     * The "read" operation of CRUD
     */
    public List<Issue> findTeamIssues(Map<String, Object> params);

    /**
     * Issue. The issue viewed on this page
     * 
         * The "read" operation of CRUD
     */
    public Issue getIssue(Map<String, Object> params);

    /**
     * Generic method to search by any property
     * 
     * @param <K>
     * @param name
     * @param value
     * @return
     *
     * @author Vineet Manohar
     */
    public <K> List<Issue> findBy(String name, K value);
}// clickframes::version=3557892506::clickframes